package com.fa.service.impl;

import com.fa.domain.Area;
import com.fa.domain.AreaSearchVO;
import com.fa.domain.AreaVO;
import com.fa.mapper.AreaMapper;
import com.fa.service.AreaService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class AreaServiceImpl implements AreaService {
    @Autowired
    private AreaMapper areaMapper;

    @Override
    public List<AreaVO> listArea(AreaSearchVO areaSearchVO) {
        List<AreaVO> areaVOS = areaMapper.listArea(areaSearchVO);
        return areaVOS;
    }

    @Override
    public AreaVO listAreaById(Long areaId) {
        AreaVO areaVO = areaMapper.listAreaById(areaId);
        return areaVO;
    }

    @Override
    public void delArea(List<Long> areaIds) {
        areaMapper.delArea(areaIds);
    }

    @Override
    public void updateArea(Area area) {
        areaMapper.updateArea(area);
    }
}
